#!/bin/sh

#quelque def
RED='\e[1;31m'
BLUE='\e[1;34m'
NC='\e[0m'              # No Color
BASE_DIR=`dirname $0`
if [ "0" -ne "$#" ] 
then
	echo -e "$BLUE Pause activee....$NC"
	PAUSE=1
fi

pause() {
	if [ -n "$PAUSE" ]
	then
		read n
	fi
}

success() {
	echo -e "$BLUE [ $1 ] $NC $2"
}

fail() {
	echo -e "${RED} [ $1 ] ${NC} $2"
}

assertEquals() {

}

PLAYER=$BASE_DIR/playRadio.sh
#Affichage de l'aide
RESULT=$($PLAYER -h)
if [ "1" -eq `echo $RESULT | grep -i usage | wc -l` ]
then 
	success test1 "Affichage aide"
else
	fail test1 "Affichage aide"
fi 
pause

#Affichage de l'aide
playRadios.sh --help
read n

#Affichage d'info de debug
playRadios.sh -V
read n

#Affichage d'info de debug
playRadios.sh --verbose
read n

#Lecture Oui FM
playRadios.sh oui
read n

#Lecture Radio Blagon
playRadios.sh -l blagon
read n


